// scripts/seed.ts
// @ts-ignore
const {PrismaClient} = require('@prisma/client');

// @ts-ignore
const db = new PrismaClient()

// @ts-ignore
async function main() {
    try {
        await db.category.createMany({
            data: [
                {name: "Computer Science"},
                {name: "Music"},
                {name: "Fitness"},
                {name: "Photography"},
                {name: "Accounting"},
                {name: "Engineering"},
                {name: "Filming"},
            ]
        })

        console.log('success')
    } catch (e) {
        console.error(e)
    } finally {
        await db.$disconnect()
    }
}

main()